export const stateJson = (state) => JSON.stringify(state);
export const snakeSpeedValue = (state) => Number(state.snake.speedValue);
export const snakeCanHitSelfValue = (state) => Boolean(state.snake.canHitSelf);
export const gameStatus = (state) => state.game.status;
export const snakeData = (state) => state.snake.data;
export const snakeHead = (state) => Number(state.snake.data[state.snake.data.length-1]);
export const snakeDirection = (state) => state.snake.direction;
export const gridRowNumControl = (state) => Number(state.control.gridRowNum);
export const gridColNumControl = (state) => Number(state.control.gridColNum);
export const gridRowNum = (state) => Number(state.board.gridRowNum);
export const gridColNum = (state) => Number(state.board.gridColNum);
export const foodData = (state) => Number(state.food.data);